Web Form - End User
When embedded in an application, the Web Form - End User widget enables end users to enter data in a designed Web Form.
Configuration Object Properties
The following table lists the properties associated with this widget.
Property | Value | Required |
---|---|---|
webformid | String , WebformID containing the webform. | Yes |
server | String , The base URL of your instance of the Qrvey platform. | Yes |
style | String , External CSS Stylesheet URL. | No |
defaultAnswers | Object Array , Option to fill an answer (just for work textFields) with default values. Multiple fields can be added, it only needs questionID and the data(string) to be inserted. Example: [{id:"UMLFTXTT",data:"Default value"}] | No |
Sample
The following sample demonstrates how this widget can be used in an HTML page.
To use this code in your application, replace the values in brackets (“<>”) with your own values.
HTML Tag:
<qrvey-webform-enduser config="config"></qrvey-webform-enduser>
Widget Launcher Script:
<script type="module" src="https://<WIDGETS_URL>/qrvey-webform-enduser/qrvey-webform-enduser/qrvey-webform-enduser.esm.js"></script>
JSON Configuration Object:
const widgetConfig = {
style: "", //CSS Stylesheet URL
webformid: "<WEB_FORM_ID>", //QrveyLookUpID
server: "https://<your_qrvey_domain>",
defaultAnswers: [{id:"7VS7I1C_",data:"ID-123456"}]
}